package StructuralPattern.Decorator;

/**
 * @Classname : FlyCarDecorator
 * @Description : 具体装饰者
 * @Author : chentianyu
 * @Date 2023/2/15 23:24
 */


public class FlyCarDecorator extends AbstractCarDecorator {

    public FlyCarDecorator(Car car) {
        super(car);
    }


    public void run() {
        super.run();
        this.fly();
    }

    // 装饰方法
    private void fly() {
        System.out.println("天上飞");
    }


}
